package com.woniu.util;

import cn.hutool.crypto.digest.MD5;
import org.springframework.stereotype.Component;

import java.nio.charset.StandardCharsets;

@Component
public class MD5Util {
    static int index = 0;
    static int count = 2;

    public String encryption(String salt,String pass){
        MD5 md5 = new MD5(salt.getBytes(StandardCharsets.UTF_8), index, count);
        return md5.digestHex(pass);
    }

}
